﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace JingQiao.Ads.Domain.Model.Repository
{
    using Domain.Model.DomainObject;
    using Infrastructure;

    public interface IDestPositionAdRepository : IRepository<IDestPositionAd>
    {
        IQueryable<IDestPositionAd> FindByAdvertisementId(int advertisementId);

        PagedResult<IDestPositionAd> Search(string name, int destinationId, int pageSize, int pageIndex);

        PagedResult<IDestPositionAd> SearchByConfig(string name, int configinfoId, int pageSize, int pageIndex);

        int CountByName(string name);

        IQueryable<IDestPositionAd> FindByAdIdAndPositionIdAndDestId(int adId, int positionId, int destId);

        IQueryable<IDestPositionAd> FindAdByDestIdAndPositionId(int destinationId, int positionId);
    }
}
